<template>
  <div class="sitemap-page">
    <page-header title="网站地图" :breadcrumb="[{text: '首页', link: '/'}, {text: '网站地图'}]"></page-header>

    <div class="sitemap-container">
      <el-row :gutter="30">
        <el-col :xs="24" :sm="12" :md="8" :lg="6" v-for="(section, index) in sitemapData" :key="index">
          <div class="sitemap-section">
            <h3>{{ section.title }}</h3>
            <ul>
              <li v-for="(link, linkIndex) in section.links" :key="linkIndex">
                <router-link :to="link.url">{{ link.text }}</router-link>
              </li>
            </ul>
          </div>
        </el-col>
      </el-row>
    </div>
  </div>
</template>

<script>
import PageHeader from '../components/PageHeader.vue'

export default {
  name: 'Sitemap',
  components: {
    PageHeader
  },
  data() {
    return {
      sitemapData: [
        {
          title: '首页',
          links: [
            { text: '首页', url: '/' }
          ]
        },
        {
          title: '关于我们',
          links: [
            { text: '公司介绍', url: '/about' },
            { text: '企业历史', url: '/about/history' },
            { text: '团队介绍', url: '/about/team' },
            { text: '组织架构', url: '/about/organization' },
            { text: '荣誉资质', url: '/about/honors' }
          ]
        },
        {
          title: '新闻资讯',
          links: [
            { text: '新闻中心', url: '/news' },
            { text: '媒体报道', url: '/news/media' },
            { text: '视频中心', url: '/news/video' }
          ]
        },
        {
          title: '产品中心',
          links: [
            { text: '产品介绍', url: '/product' },
            { text: '企业创新', url: '/product/innovation' },
            { text: '社会责任', url: '/product/social' }
          ]
        },
        {
          title: '服务支持',
          links: [
            { text: '业务领域', url: '/boxs' },
            { text: '服务范围', url: '/boxs/services' },
            { text: '项目案例', url: '/boxs/projects' }
          ]
        },
        {
          title: '文档中心',
          links: [
            { text: '文档列表', url: '/docs' }
          ]
        },
        {
          title: '招聘信息',
          links: [
            { text: '招聘概览', url: '/recruits' },
            { text: '校园招聘', url: '/recruits/campus' },
            { text: '社会招聘', url: '/recruits/social' },
            { text: '实习生招聘', url: '/recruits/intern' }
          ]
        },
        {
          title: '联系我们',
          links: [
            { text: '联系方式', url: '/touch' }
          ]
        },
        {
          title: '其他',
          links: [
            { text: '搜索', url: '/search' },
            { text: '隐私政策', url: '/legal/privacy' },
            { text: '使用条款', url: '/legal/terms' }
          ]
        }
      ]
    }
  },
  metaInfo: {
    title: '网站地图 - 企业门户'
  }
}
</script>

<style scoped>
.sitemap-page {
  padding-bottom: 60px;
}

.sitemap-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.sitemap-section {
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 12px 0 rgba(0,0,0,0.05);
  padding: 20px;
  margin-bottom: 30px;
  height: calc(100% - 30px);
  transition: all 0.3s ease;
}

.sitemap-section:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.sitemap-section h3 {
  color: var(--el-color-primary);
  font-size: 18px;
  margin-top: 0;
  margin-bottom: 15px;
  padding-bottom: 10px;
  border-bottom: 1px solid #ebeef5;
}

.sitemap-section ul {
  padding-left: 0;
  list-style: none;
  margin: 0;
}

.sitemap-section li {
  margin-bottom: 10px;
  position: relative;
  padding-left: 15px;
}

.sitemap-section li:before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--el-color-primary-light-7);
}

.sitemap-section a {
  color: #606266;
  text-decoration: none;
  transition: color 0.3s;
}

.sitemap-section a:hover {
  color: var(--el-color-primary);
}

@media (max-width: 768px) {
  .sitemap-section {
    margin-bottom: 20px;
  }
}
</style>
